1 {strip}
2 <table border="0"><tr>
3 {* show page rank *}
4 {if $smarty.const.SHOW_PAGERANK}
5 <td>
6 {include file="pagerank.tpl" pr=$link.PAGERANK}
7 </td>
8 {/if}
9
10 <td>
11 {if $edit_link}
12 <span id="T_{$link.ID}">{$link.TITLE|escape|trim}</span>
13
14
15 {if !empty($link.URL)}
16
17 <a class="link" id="id_{$link.ID}" href="{$link.URL|escape|trim}" title="{$link.TITLE|escape|trim}"
18 {if $link.NOFOLLOW} rel="nofollow"{/if}
19 target="_blank">
20 <span class="link"><img src="{$smarty.const.DOC_ROOT}/images/external_link.png" alt="{$link.TITLE|escape|trim}" border="0"/></span>
21 </a>
22 {/if}
23 {else}
24 <a class="link" id="id_{$link.ID}" href="{$link.URL|escape|trim}" title="{$link.TITLE|escape|trim}"
25 {if $link.NOFOLLOW} rel="nofollow"{/if}
26 target="_blank">{$link.TITLE|escape|trim}</a> {/if}
27 <br/>
28 {if !empty ($search) or !empty ($uid)}
29 <p>{l}Category{/l}: <a href="{$smarty.const.DOC_ROOT}/{$link.CATEGORY_URL|escape|trim}" title="{$link.CATEGORY_TITLE|escape|trim}">{$link.CATEGORY_TITLE|escape|trim}</a></p>
30 {/if}
31 {if $link.URL}
32 {if $edit_link}
33
34 <span class="link" id="U_{$link.ID}" style="color: #3E81B4;">{$link.URL|escape|trim}</span>
35
36 {else}
37 <span class="link">{$link.URL|escape|trim}</span>
38 {/if}
39 {/if}
40 {if $link.DESCRIPTION}
41 <p id="description{$link.ID}">
42 <span id="editdescrip_{$link.ID}">{if !empty($link.DESCRIPTION)}{$link.DESCRIPTION|trim}{else}[{l}No Description{/l}]{/if}</span>
43 </p>
44 {/if}
45 <p>
46 <a class="readMore" href="{if !$smarty.const.ENABLE_REWRITE}
47 {$smarty.const.DOC_ROOT}/detail.php?id={$link.ID}
48 {else}
49 {$smarty.const.DOC_ROOT}/{$link.SEO_URL}{/if}" title="{l}Read more about{/l}: {$link.TITLE|escape|trim}">{l}Read more{/l}</a>
50 {if ($smarty.const.REQUIRE_REGISTERED_USER == 1 || $smarty.const.REQUIRE_REGISTERED_USER_ARTICLE == 1) and !empty ($regular_user_details) and ($regular_user_details.ID == $link.OWNER_ID)}
51 , <a class="readMore" href="{$smarty.const.DOC_ROOT}/submit.php?linkid={$link.ID}" title="{l}Edit or Remove your link{/l}">{l}Review{/l}</a>
52 {/if}
53 </p>
54 </td>
55 </tr>
56 <tr>
57 <td colspan="2">{if $ratings_on == 1}{if $smarty.const.LINK_RATING_DISPLAY == 'image'}
58 <div class="link_rating" style="width:400px;">
59 {if $link.RATING >0 }
60 {section name=foo loop=$link.RATING/$link.VOTES}
61 <img src="{$smarty.const.DOC_ROOT}/templates/{$smarty.const.USE_TEMPLATE}/images/tiny_star.gif">
62 {/section}
63 {if intval($link.RATING/$link.VOTES) < $link.RATING/$link.VOTES}
64 <img src="{$smarty.const.DOC_ROOT}/templates/{$smarty.const.USE_TEMPLATE}/images/tiny_star_half.gif">
65 {/if}
66 {else}
67 <span class="review" style="float: left; padding-bottom: 3px;padding-left: 3px;">not rated yet</span>
68 {/if}
69 {/if} {/if}
70 <span class="review">{if $comments_on == 1}{if $link.COMMENT_COUNT !=''}{$link.COMMENT_COUNT}{else}0{/if} Reviews.{/if}{if $ratings_on == 1} Rating: {$link.RATING/$link.VOTES|truncate:4:""} Total Votes: {if !$link.VOTES}0{else}{$link.VOTES}{/if}{/if}</span>
71 <div style="clear: both;"></div>
72 </div>
73 </td>
74 </tr>
75 <tr>
76 <td colspan="2">
77 {if $link.rights.editLink eq 1}
78 <a href="{$smarty.const.DOC_ROOT}/inplace_editlink.php?ID={$link.ID}&TB_iframe=true&height=400&width=600" target="blank" class="thickbox" onclick="{literal}return showThickbox(this);{/literal}">
79 <img src="{$smarty.const.DOC_ROOT}/templates/{$smarty.const.USE_TEMPLATE}/images/edit.gif" width="14" height="14" style="border: none;" alt="edit link"/>
80 </a>
81
82 {/if}
83 {if $link.rights.delLink eq 1}
84 <a href="{$smarty.const.DOC_ROOT}/inplace_editlink.php?ID={$link.ID}&mode=del&TB_iframe=true&height=100&width=250" class="thickbox" onclick="{literal}question = confirm('Are you sure you want to delete this link?');if (question !='0'){return showThickbox(this);} else return false;{/literal}">
85 <img src="{$smarty.const.DOC_ROOT}/templates/{$smarty.const.USE_TEMPLATE}/images/delete.gif" width="14" height="14" style="border: none;" alt="delete link"/>
86 </a>
87 {/if}
88 {if ($link.STATUS<2) && $link.rights.editLink eq 1}
89 <a href="{$smarty.const.DOC_ROOT}/inplace_editlink.php?ID={$link.ID}&mode=active&TB_iframe=true&height=100&width=250" class="thickbox" onclick="{literal}question = confirm('Are you sure you want to make this link active?');if (question !='0'){return showThickbox(this);} else return false;{/literal}">
90 <img src="{$smarty.const.DOC_ROOT}/templates/{$smarty.const.USE_TEMPLATE}/images/active.gif" width="14" height="14" style="border: none;" alt="category is inactive" class="float_tiny"/>
91 </a>
92 {/if}
93 {if $link.rights.editLink eq 1 || $link.rights.delLink eq 1}
94 {if $link.has_payment > 0}
95 <div class="float_tiny" style="color: green; font-weight: bold">$</div>
96 {/if}
97 {/if}
98 </td>
99 </tr>
100 </table>
101 {/strip}
102 {if $edit_link}
103 {literal}
104 <script type="text/javascript">
105 new Ajax.InPlaceEditor({/literal}'T_{$link.ID}', '{$smarty.const.DOC_ROOT}/admin/frontend_edit_link.php?a=T_{$link.ID}',{literal} {savingText:{/literal}'<img src="{$smarty.const.DOC_ROOT}/images/indicator.gif" />',{literal} size:30});
106 new Ajax.InPlaceEditor({/literal}'U_{$link.ID}', '{$smarty.const.DOC_ROOT}/admin/frontend_edit_link.php?a=U_{$link.ID}',{literal} {savingText:{/literal}'<img src="{$smarty.const.DOC_ROOT}/images/indicator.gif" />',{literal} size:30});
107 </script>
108 {/literal}
109 {/if}